<?php 
	//error_reporting(E_ALL);
 	//ini_set("display_errors", 1);
 	   
	include_once './templates/display.php';
    include_once './templates/modules.php';
    
	Displayer::displayHeader('Shop');

    $id = $_GET["id"];

    $product = ProduitManager::getProduit($id);

    echo ' <div id="det_image">
                <img src="Images/products/'.$product->getPathImage().'" alt=""/>
           </div>
           
           <div id="det_productname">'.$product->getNom().'</div>
           
           <div id="det_price">'.$product->getPrix().' €</div>
		   
			   
           <div id="det_qte_region">
               <div>
                    Quantité
               </div>
               <div id="det_qte_block">
					    <div class="det_selector" onclick="change_qte(\''.$product->getId().'\', \'add\')">+</div>

				        <input id="det_qte" type="text" readonly value="1">
				
				        <div class="det_selector" onclick="change_qte(\''.$product->getId().'\', \'remove\')">-</div>
		       </div>
			   
				<div id="qteStock">'.$product->getQteStock().' unit&#233;(s) en stock </div>
           </div>
		
           <div id="det_addtocart" onclick="modify_cart(\''.$product->getId().'\',\'add\',\'custom_qte\')">Ajouter au panier</div>';
    

	Displayer::displayFooter();
?>
